
<!DOCTYPE html>
<html lang="en">

	<head>

		<!-- Basic -->
		<meta charset="UTF-8" />

		<title>自夏学院 | Fire - Admin Template</title>

		<!-- Mobile Metas -->
		<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />

		<!-- Import google fonts -->

		<!-- Favicon and touch icons -->
		<link rel="shortcut icon" href="../../assets/ico/favicon.ico" type="image/x-icon" />
		<link rel="apple-touch-icon" href="../../assets/ico/apple-touch-icon.png" />
		<link rel="apple-touch-icon" sizes="57x57" href="../../assets/ico/apple-touch-icon-57x57.png" />
		<link rel="apple-touch-icon" sizes="72x72" href="../../assets/ico/apple-touch-icon-72x72.png" />
		<link rel="apple-touch-icon" sizes="76x76" href="../../assets/ico/apple-touch-icon-76x76.png" />
		<link rel="apple-touch-icon" sizes="114x114" href="../../assets/ico/apple-touch-icon-114x114.png" />
		<link rel="apple-touch-icon" sizes="120x120" href="../../assets/ico/apple-touch-icon-120x120.png" />
		<link rel="apple-touch-icon" sizes="144x144" href="../../assets/ico/apple-touch-icon-144x144.png" />
		<link rel="apple-touch-icon" sizes="152x152" href="../../assets/ico/apple-touch-icon-152x152.png" />

		<!-- start: CSS file-->

		<!-- Vendor CSS-->
		<link href="../../assets/vendor/bootstrap/css/bootstrap.min.css" rel="stylesheet" />
		<link href="../../assets/vendor/skycons/css/skycons.css" rel="stylesheet" />
		<link href="../../assets/vendor/font-awesome/css/font-awesome.min.css" rel="stylesheet" />
		<link href="../../assets/vendor/css/pace.preloader.css" rel="stylesheet" />

		<!-- Plugins CSS-->
		<link href="../../assets/plugins/jquery-ui/css/jquery-ui-1.10.4.min.css" rel="stylesheet" />
		<link href="../../assets/plugins/scrollbar/css/mCustomScrollbar.css" rel="stylesheet" />
		<link href="../../assets/plugins/bootkit/css/bootkit.css" rel="stylesheet" />
		<link href="../../assets/plugins/magnific-popup/css/magnific-popup.css" rel="stylesheet" />
		<link href="../../assets/plugins/fullcalendar/css/fullcalendar.css" rel="stylesheet" />
		<link href="../../assets/plugins/jqvmap/jqvmap.css" rel="stylesheet" />

		<!-- Theme CSS -->
		<link href="../../assets/css/jquery.mmenu.css" rel="stylesheet" />

		<!-- Page CSS -->
		<link href="../../assets/css/style.css" rel="stylesheet" />
		<link href="../../assets/css/add-ons.min.css" rel="stylesheet" />

		<!-- end: CSS file-->

		<!-- Head Libs -->
		<script src="../../assets/plugins/modernizr/js/modernizr.js"></script>

		<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
		<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
		<!--[if lt IE 9]>
			<script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
			<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
		<![endif]-->

	</head>

	<body>

		<!-- Start: Header -->
		<div class="navbar" role="navigation">
			<div class="container-fluid container-nav">
				<!-- Navbar Action -->
				<ul class="nav navbar-nav navbar-actions navbar-left">
					<li class="visible-md visible-lg"><a href="#" id="main-menu-toggle"><i class="fa fa-th-large"></i></a></li>
					<li class="visible-xs visible-sm"><a href="#" id="sidebar-menu"><i class="fa fa-navicon"></i></a></li>
				</ul>
				<!-- Navbar Left -->
				<div class="navbar-left">
					<!-- Search Form -->
					<form class="search navbar-form">
						<div class="input-group input-search">
							<input type="text" class="form-control bk-radius" name="q" id="q" placeholder="Search...">
							<span class="input-group-btn">
								<button class="btn btn-default" type="submit"><i class="fa fa-search"></i></button>
							</span>
						</div>
					</form>
				</div>
				<!-- Navbar Right -->
				<div class="navbar-right">
					 
					<div class="userbox" id="uerpicname">
						 
						<!--<a href=" " class="dropdown-toggle" data-toggle="dropdown">
							<figure class="profile-picture hidden-xs">
								<img src="img/uerimg.jpg" class="img-circle" alt="" />
							</figure>
							<div class="profile-info">
								<span class="name">John Smith Doe</span> 
							</div> 
						</a> -->
					</div>
					 
					<button class="btn btn-success" id="Nextnull" type="button">退出当前用户</button>
				</div>
				<!-- End Navbar Right -->
			</div>
		</div>
		<!-- End: Header -->

		<!-- Start: Content -->
		<div class="container-fluid content">
			<div class="row">

				<!-- Sidebar -->
				<div class="sidebar">
					<div class="sidebar-collapse">
						<!-- Sidebar Header Logo-->
						<div class="sidebar-header">
              <img src="../img/logo.png" class="img-flags" alt="" style="width: 60%;"/>
						</div>
						<!-- Sidebar Menu-->
						<div class="sidebar-menu">
							<nav id="menu" class="nav-main" role="navigation">
								<ul class="nav nav-sidebar">
									<div class="panel-body text-center">
										<div class="flag">
											<!--<img src="../img/log.jpg" class="img-flags" alt="" />-->
										</div>
									</div>
									<li class="active">
										<a href="index.html">
											<i class="fa fa-laptop" aria-hidden="true"></i><span>自夏学院</span>
										</a>
									</li>

									<li class="nav-parent">
										<a>
											<i class="fa fa-copy" aria-hidden="true"></i><span>论坛分类</span>
										</a>
										<ul class="nav nav-children">
											<li><a href="PrimaryClassification.html"><span class="text">二级论坛</span></a>
												
												
											</li>
											<li><a href="AddPrimaryClassification.html"><span class="text">添加论坛分类</span></a></li>
										</ul>
									</li>
									<li class="nav-parent">
										<a>
											<i class="fa fa-copy" aria-hidden="true"></i><span>二级论坛</span>
										</a>
										<ul class="nav nav-children">
											<li><a href="forumbinfo.html"><span class="text">论坛信息</span></a></li>
											<li><a href="Addforumbinfo.html"><span class="text">添加论坛内容</span></a></li>
										</ul>
									</li>
									<li class="nav-parent">
										<a>
											<i class="fa fa-copy" aria-hidden="true"></i><span>管理留言</span>
										</a>
										<ul class="nav nav-children">
											<li><a href="forumcomment.html"><span class="text">论坛留言</span></a></li>
											<li><a href="Addforumcomment.html"><span class="text">添加留言</span></a></li>
										</ul>
									</li>
								</ul>
							</nav>
						</div>
						<!-- End Sidebar Menu-->
					</div>
					<!-- Sidebar Footer-->
					<div class="sidebar-footer" style="display: none;">

					</div>
					<!-- End Sidebar Footer-->
				</div>
				<!-- End Sidebar -->

				<!-- Main Page -->
				<div class="main ">
					<!-- Page Header -->
					<div class="page-header">
						<div class="pull-left">
							<ol class="breadcrumb visible-sm visible-md visible-lg">
								<li><a href="index.html"><i class="icon fa fa-home"></i>Home</a></li>
								<li class="active"><i class="fa fa-laptop"></i>自夏学院</li>
							</ol>
						</div>
						<div class="pull-right">
							<h2>自夏学院</h2>
						</div>
					</div>
					<!-- End Page Header -->

					<div class="col-sm-12">
						<div class="panel panel-default bk-bg-white">
							<div class="panel-heading bk-bg-white">
								<h6><i class="fa fa-indent red"></i>Validation States Form</h6>
								<div class="panel-actions">
									<a href="#" class="btn-minimize"><i class="fa fa-caret-up"></i></a>
									<a href="#" class="btn-close"><i class="fa fa-times"></i></a>
								</div>
							</div>

							<form method="post" action="/forum/updatefouramB" class="panel-body" enctype="multipart/form-data">
								<div class="form-group has-success">
									<label class="control-label" for="inputSuccess1">论坛编号</label>
									<input type="text" class="form-control" name="fourBmId" value="<%=msg[0].forumBId%>" readonly>
								</div>
								<div class="form-group has-success">
									<label class="control-label" for="inputSuccess1">论坛名称</label>
									<input type="text" class="form-control" name="fouramBname" value="<%=msg[0].forumBName%>">
								</div>
                <div class="form-group has-success">
                  <label class="control-label" for="inputSuccess1">论坛图片</label>
                  <img src="../img/<%=msg[0].forumbPic%>" style="width: 50px" name="forumbPic" />
                  <input type="file" name="newsPic" />
                </div>
								<div class="form-group has-success">
									<label class="control-label" for="inputSuccess1">论坛发布者</label>
									<select name="forumA" style="width: 180px;height: 30px">
										<%for(var i=0;i<user.length;i++){%>
										<%if(user[i].userId==msg[0].userId){%>
										<option value="<%=user[i].userId%>" checked><%=user[i].userName%></option>
										<%}else{%>
										<option value="<%=user[i].userId%>"><%=user[i].userName%></option>
										<%}%>
										<%}%>
									</select>
								</div>
								<div class="form-group has-success">
									<label class="control-label" for="inputSuccess1">论坛发布时间</label>
									<input type="text" class="form-control" name="forumBTime" value="<%=msg[0].forumBTime.toLocaleString() %>" readonly >
								</div>
								<div class="form-group has-success">
									<label class="control-label" for="inputSuccess1">论坛是否置顶</label>
									<select name="forumBUp"style="width: 80px;height: 30px">
										<%if(parseInt(msg[0].forumBUp)==0){%>
											<option value="<%=msg[0].forumBUp%>" checked="checked">否</option>
											<option value="1">是</option>
										<%}else{%>
											<option value="<%=msg[0].forumBUp%>" checked="checked">是</option>
											<option value="0">否</option>
										<%}%>
									</select>
								</div>
								<div class="form-group has-success">
									<label class="control-label" for="inputSuccess1">论坛所属分类</label>
									<select name="forumA" style="width: 180px;height: 30px">
										<%for(var i=0;i<forumA.length;i++){%>
											<%if(forumA[i].forumAId==msg[0].forumAId){%>
												<option value="<%=forumA[i].forumAId%>" checked><%=forumA[i].forumAName%></option>
											<%}else{%>
										<option value="<%=forumA[i].forumAId%>"><%=forumA[i].forumAName%></option>
											<%}%>
										<%}%>
									</select>

								</div>

								<button type="submit" class="bk-margin-5 btn btn-success">修改分类</button>

							</form>
						</div>
					</div>

					<!-- End Main Page -->

					<!-- Footer -->
					
					<!-- End Footer -->

				</div>
			</div>
			<!--/container-->

			<div class="clearfix"></div>

			<!-- start: JavaScript-->

			<!-- Vendor JS-->
			<script src="../../assets/vendor/js/jquery.min.js"></script>
			<script src="../../assets/vendor/js/jquery-2.1.1.min.js"></script>
			<script src="../../assets/vendor/js/jquery-migrate-1.2.1.min.js"></script>
			<script src="../../assets/vendor/bootstrap/js/bootstrap.min.js"></script>
			<script src="../../assets/vendor/skycons/js/skycons.js"></script>
			<script src="../../assets/vendor/js/pace.min.js"></script>

			<!-- Plugins JS-->
			<script src="../../assets/plugins/jquery-ui/js/jquery-ui-1.10.4.min.js"></script>
			<script src="../../assets/plugins/scrollbar/js/jquery.mCustomScrollbar.concat.min.js"></script>
			<script src="../../assets/plugins/bootkit/js/bootkit.js"></script>
			<script src="../../assets/plugins/magnific-popup/js/magnific-popup.js"></script>
			<script src="../../assets/plugins/moment/js/moment.min.js"></script>
			<script src="../../assets/plugins/fullcalendar/js/fullcalendar.js"></script>
			<script src="../../assets/plugins/flot/js/jquery.flot.min.js"></script>
			<script src="../../assets/plugins/flot/js/jquery.flot.pie.min.js"></script>
			<script src="../../assets/plugins/flot/js/jquery.flot.resize.min.js"></script>
			<script src="../../assets/plugins/flot/js/jquery.flot.stack.min.js"></script>
			<script src="../../assets/plugins/flot/js/jquery.flot.time.min.js"></script>
			<script src="../../assets/plugins/flot-tooltip/js/jquery.flot.tooltip.js"></script>
			<script src="../../assets/plugins/chart-master/js/Chart.js"></script>
			<script src="../../assets/plugins/jqvmap/jquery.vmap.js"></script>
			<script src="../../assets/plugins/jqvmap/data/jquery.vmap.sampledata.js"></script>
			<script src="../../assets/plugins/jqvmap/maps/jquery.vmap.world.js"></script>
			<script src="../../assets/plugins/sparkline/js/jquery.sparkline.min.js"></script>

			<!-- Theme JS -->
			<script src="../../assets/js/jquery.mmenu.min.js"></script>
			<script src="../../assets/js/core.min.js"></script>
      <script type="text/javascript" src="../js/jquery-2.1.0.js"></script>
      <script type="text/javascript" src="../js/jquery.form.js"></script>
			<!-- end: JavaScript-->

	</body>
  <script>
    $(function () {
      var bar = $('.bar');
      var percent = $('.percent');
      var showimg = $('#showimg');
      var progress = $(".progress");
      var files = $(".files");
      var btn = $(".btn span");
      $("#fileupload").wrap("<form id='myupload' action='../php/action.php' method='post' enctype='multipart/form-data'></form>");
      $("#fileupload").change(function(){
        $("#myupload").ajaxSubmit({
          dataType:  'json',
          beforeSend: function() {
            showimg.empty();
            progress.show();
            var percentVal = '0%';
            bar.width(percentVal);
            percent.html(percentVal);
            btn.html("上传中...");
          },
          uploadProgress: function(event, position, total, percentComplete) {
            var percentVal = percentComplete + '%';
            bar.width(percentVal);
            percent.html(percentVal);
          },
          success: function(data) {
            files.html("<b>"+data.name+"("+data.size+"k)</b>");
            var img = "img/"+data.pic;
            showimg.html("<img src='../"+img+"'>");
            btn.html("添加附件");
          },
          error:function(xhr){
            btn.html("上传失败");
            bar.width('0')
            files.html(xhr.responseText);
          }
        });
      });


    });
  </script>
</html>
